

<%@ page import="com.surelution.projects.crm.MemberCard" %>
<html>
    <head>
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
        <meta name="layout" content="main" />
        <g:set var="entityName" value="${message(code: 'memberCard.label', default: 'MemberCard')}" />
        <title><g:message code="default.create.label" args="[entityName]" /></title>
    </head>
    <body>
        <div class="nav">
            <span class="menuButton"><a class="home" href="${createLink(uri: '/')}"><g:message code="default.home.label"/></a></span>
            <span class="menuButton"><g:link class="list" action="list"><g:message code="default.list.label" args="[entityName]" /></g:link></span>
        </div>
        <div class="body">
            <h1><g:message code="default.create.label" args="[entityName]" /></h1>
            <g:if test="${flash.message}">
            <div class="message">${flash.message}</div>
            </g:if>
            <g:hasErrors bean="${memberCardInstance}">
            <div class="errors">
                <g:renderErrors bean="${memberCardInstance}" as="list" />
            </div>
            </g:hasErrors>
            <g:form action="save" >
                <div class="dialog">
                    <table>
                        <tbody>
                        
                            <tr class="prop">
                                <td valign="top" class="name">
                                    <label for="accountAcceptBranch"><g:message code="memberCard.accountAcceptBranch.label" default="Account Accept Branch" /></label>
                                </td>
                                <td valign="top" class="value ${hasErrors(bean: memberCardInstance, field: 'accountAcceptBranch', 'errors')}">
                                    <g:textField name="accountAcceptBranch" value="${memberCardInstance?.accountAcceptBranch}" />
                                </td>
                            </tr>
                        
                            <tr class="prop">
                                <td valign="top" class="name">
                                    <label for="accountAcceptDate"><g:message code="memberCard.accountAcceptDate.label" default="Account Accept Date" /></label>
                                </td>
                                <td valign="top" class="value ${hasErrors(bean: memberCardInstance, field: 'accountAcceptDate', 'errors')}">
                                    <g:datePicker name="accountAcceptDate" precision="day" value="${memberCardInstance?.accountAcceptDate}"  />
                                </td>
                            </tr>
                        
                            <tr class="prop">
                                <td valign="top" class="name">
                                    <label for="cardNo"><g:message code="memberCard.cardNo.label" default="Card No" /></label>
                                </td>
                                <td valign="top" class="value ${hasErrors(bean: memberCardInstance, field: 'cardNo', 'errors')}">
                                    <g:textField name="cardNo" value="${memberCardInstance?.cardNo}" />
                                </td>
                            </tr>
                        
                            <tr class="prop">
                                <td valign="top" class="name">
                                    <label for="connectTime"><g:message code="memberCard.connectTime.label" default="Connect Time" /></label>
                                </td>
                                <td valign="top" class="value ${hasErrors(bean: memberCardInstance, field: 'connectTime', 'errors')}">
                                    <g:datePicker name="connectTime" precision="day" value="${memberCardInstance?.connectTime}"  />
                                </td>
                            </tr>
                        
                            <tr class="prop">
                                <td valign="top" class="name">
                                    <label for="holderName"><g:message code="memberCard.holderName.label" default="Holder Name" /></label>
                                </td>
                                <td valign="top" class="value ${hasErrors(bean: memberCardInstance, field: 'holderName', 'errors')}">
                                    <g:textField name="holderName" value="${memberCardInstance?.holderName}" />
                                </td>
                            </tr>
                        
                            <tr class="prop">
                                <td valign="top" class="name">
                                    <label for="isMaster"><g:message code="memberCard.isMaster.label" default="Is Master" /></label>
                                </td>
                                <td valign="top" class="value ${hasErrors(bean: memberCardInstance, field: 'isMaster', 'errors')}">
                                    <g:checkBox name="isMaster" value="${memberCardInstance?.isMaster}" />
                                </td>
                            </tr>
                        
                            <tr class="prop">
                                <td valign="top" class="name">
                                    <label for="market"><g:message code="memberCard.market.label" default="Market" /></label>
                                </td>
                                <td valign="top" class="value ${hasErrors(bean: memberCardInstance, field: 'market', 'errors')}">
                                    <g:select name="market.id" from="${com.surelution.projects.crm.Market.list()}" optionKey="id" value="${memberCardInstance?.market?.id}"  />
                                </td>
                            </tr>
                        
                        </tbody>
                    </table>
                </div>
                <div class="buttons">
                    <span class="button"><g:submitButton name="create" class="save" value="${message(code: 'default.button.create.label', default: 'Create')}" /></span>
                </div>
            </g:form>
        </div>
    </body>
</html>
